using System;
using LambdaGp.Core;

namespace LambdaGp.Operators.Functions.MathFunctions
{
    public class Sub : BinaryFunction
    {
        public Sub()
            : base("-")
        {
        }

        protected override Func<double> CompileBinaryToFunc(Individual individual, Func<double> first, Func<double> second)
        {
            return () => first() - second();
        }
    }
}
